# -*- coding: utf-8 -*-
"""
@Time ： 2023/4/20 20:55
@Auth ： 叶东宇
@File ：reverseString.py
"""

def reverseString(lis):

    if len(lis) == 0:
        return lis
    if len(lis) == 1:
        return lis

    left = 0
    right = len(lis) - 1
    while left < right:
        tmp_1 = lis[left]
        tmp_2 = lis[right]
        lis[left] = tmp_2
        lis[right] = tmp_1
        left += 1
        right -= 1

    return lis


if __name__ == "__main__":
    lis = ['1','2','3','4']
    print(reverseString(lis))